package com.liangwei.jd.service;

import com.google.common.collect.Maps;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.util.Map;
import java.util.concurrent.ConcurrentMap;
import java.util.concurrent.Future;
import java.util.concurrent.LinkedBlockingQueue;

/**
 * @author liangweih
 * @since 2019/3/14 15:23
 */

 public class Constant {
    private static final Logger log = LoggerFactory.getLogger(Constant.class);
static
{
    log.info("path----"+System.getProperty("user.dir"));
}

    public   static Map<String, Future<?>> aliveThreadFutureMap = Maps.newConcurrentMap();



    public static ConcurrentMap<String, Integer>   updateUserInfo=Maps.newConcurrentMap();


     public final static  String USERINFO="userinfo",INDICATOR="indicator",TRENDCHART="trendchart",INDICATOR2="indicator2",TRENDCHART2="trendchart2",JZTUSERRPT="jztuserrpt",TREND="trend";


    /**
     * 分割份数
     */
    public static int CUTTING_VALUE=12;
    /**
     * 验证码宽
     */
    public static int CODE_WIDTTH=360;
    /**
     * 补偿像素
     */

    public  static int COMPENSATE_VALUE=7;

    /**
     * 位移系数
     */
    public  static double COEFFICIENT = 0.78;
    /**
     * 偏移倍数，  1倍数+0.01系数
     */
    public static int DEVIATION_PIXEL = 36;
    public static final String YT_IMAGER_URL = System.getProperty("user.dir")+"/src/main/resources/yt";


    /**
     * 账号
     */
 public final static String ELEMENT_USERNAME_ID = "loginname";
     /**
     * 密码
      */
     public  final static String ELEMENT_PASSWORD_ID = "nloginpwd";

    /**
     * 登录按钮
     */
    public  final static String ELEMENT_SUBMIT_ID = "loginsubmit";
    /**
     * 验证码缺口图
     */
    public final static String ELEMENT_CODE_IMG_SRC_XPATH="//div[@class='JDJRV-bigimg']/img";

    /**
     * 验证码刷新标签
     */

    public final static String ELEMENT_CODE_REFRESH_CLASSNAME="JDJRV-img-refresh";
    /**
     * 验证码滑块
     */
    public  final  static String ELEMENT_CODE_SLIDER_CLASSNAME="JDJRV-smallimg";

}
